home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload Trio 2
/
Shareware Overload Trio Volume 2 (Chestnut CD-ROM).ISO
/
dir42
/
cdd3007b.zip
/
CDD6TO7.BAT
< prev
next >
Wrap
DOS Batch File
|
1994-01-21
|
16KB
|
387 lines
@ECHO OFF
CLS
IF "%1"=="" GOTO SYNTAX
ECHO ╔═════════════════════════════════════════════════════════════╗
ECHO ║ CDD 3.O patch for version 3006 ║
ECHO ║ ║
ECHO ║ This patchfile implements fixes to CDD version 3006. This ║
ECHO ║ patch will ONLY work on CDD version 3006. ║
ECHO ╚═════════════════════════════════════════════════════════════╝
ECHO ╔═════════════════════════════════════════════════════════════╗
ECHO ║ If you are using a version prior to 3006, you can order ║
ECHO ║ a complete install set from the Customer Service department ║
ECHO ║ at 305-785-4555, for $10.00 plus shipping charges. ║
ECHO ╚═════════════════════════════════════════════════════════════╝
ECHO ╔═════════════════════════════════════════════════════════════╗
ECHO ║ Press any key to continue or Control-C to abort. ║
ECHO ╚═════════════════════════════════════════════════════════════╝
pause
if not exist PATCH.EXE GOTO missing_file
if not exist ISIT3006.RTP GOTO missing_file
if not exist CDD6TO7.RTP GOTO missing_file
if not exist 6TO7CONT.RTP GOTO missing_file
ECHO ╔══════════════════════════════════╗
ECHO ║ Verifying that the 3006 version ║
ECHO ║ of CLARION3.EXE is installed in: ║ " %1 "
ECHO ╚══════════════════════════════════╝
PATCH %1 -E ISIT3006.RTP
IF ERRORLEVEL 37 GOTO ERRORFILE
IF ERRORLEVEL 36 GOTO BADVER
IF ERRORLEVEL 35 GOTO SYNTAX
IF ERRORLEVEL 34 GOTO NOTADIR
IF ERRORLEVEL 29 GOTO NOSPACE
IF ERRORLEVEL 24 GOTO CONT_PATCH
IF ERRORLEVEL 16 GOTO CONT_PATCH
IF ERRORLEVEL 15 GOTO BADVER_15
IF ERRORLEVEL 9 GOTO BAD_PATCHFILE
IF ERRORLEVEL 8 GOTO BAD_PATCHEXE
IF ERRORLEVEL 5 GOTO NOTADIR
IF ERRORLEVEL 4 GOTO NOTADIR
IF ERRORLEVEL 1 GOTO SYNTAX
ECHO ╔════════════════════════════════════════════════════════════════════════╗
ECHO ║ The 3006 version of Clarion3.exe has been patched! ║
ECHO ║ Before applying the PATCH for CDD we can make copies of the following ║
ECHO ║ files: *.TXT, *.HLP, ???BROWS.*, ???REPEA.*, CLARION.APP ║
ECHO ║ : BROWSE.INC, REPEAT.INC, BROWSE.PR, REPEAT.PR ║
ECHO ║ : *.TP?, the Clarion *.HLP and *.TXT files ║
ECHO ╚════════════════════════════════════════════════════════════════════════╝
GOTO START_BACKUP
:CONT_PATCH
ECHO ╔════════════════════════════════════════════════════════════════════════╗
ECHO ║ Found a 3007 version of Clarion3.exe ! ║
ECHO ║ the 3006 version of Clarion3.exe has ALREADY been patched! ║
ECHO ║ Before applying the PATCH for CDD we can make copies of the following ║
ECHO ║ files: *.TXT, *.HLP, ???BROWS.*, ???REPEA.*, CLARION.APP ║
ECHO ║ : BROWSE.INC, REPEAT.INC, BROWSE.PR, REPEAT.PR ║
ECHO ║ : CLARION??.TP?, the Clarion *.HLP and *.TXT files ║
ECHO ╚════════════════════════════════════════════════════════════════════════╝
GOTO START_BACKUP
:START_BACKUP
YESNO Should we make copies of these files? [Y/N]
IF ERRORLEVEL 1 GOTO skip_backup
ECHO ╔═════════════════════════════════════════╗
ECHO ║ FILES WILL BE COPIED to the directory: ║ %1\SAVECDD
ECHO ╚═════════════════════════════════════════╝
MD %1\SAVECDD >nul
COPY CDD6TO7.BAT %1\SAVECDD >nul
if not exist %1\SAVECDD\CDD6TO7.BAT GOTO DIRTEST_FAILED
DEL %1\SAVECDD\CDD6TO7.BAT >nul
ECHO Copying files from %1 to %1\SAVECDD\*.*
copy %1\*.tp? %1\SAVECDD >nul
copy %1\appgn.txt %1\SAVECDD >nul
copy %1\clarion.txt %1\SAVECDD >nul
copy %1\txted.txt %1\SAVECDD >nul
copy %1\envir.txt %1\SAVECDD >nul
copy %1\hlped.txt %1\SAVECDD >nul
copy %1\rptwr.txt %1\SAVECDD >nul
copy %1\cshell.txt %1\SAVECDD >nul
copy %1\dbmmg.txt %1\SAVECDD >nul
copy %1\dcted.txt %1\SAVECDD >nul
copy %1\clarion.hlp %1\SAVECDD >nul
copy %1\clarion3.hlp %1\SAVECDD >nul
copy %1\editor.hlp %1\SAVECDD >nul
copy %1\cshell.hlp %1\SAVECDD >nul
copy %1\clarion.sty %1\SAVECDD >nul
copy %1\standard.sty %1\SAVECDD >nul
copy %1\neon.sty %1\SAVECDD >nul
copy %1\browse.cla %1\SAVECDD >nul
copy %1\browse.pr %1\SAVECDD >nul
copy %1\browse.inc %1\SAVECDD >nul
copy %1\???brows.dll %1\SAVECDD >nul
copy %1\lib\???brows.lib %1\SAVECDD >nul
copy %1\repeat.cla %1\SAVECDD >nul
copy %1\repeat.pr %1\SAVECDD >nul
copy %1\repeat.inc %1\SAVECDD >nul
copy %1\???repea.dll %1\SAVECDD >nul
copy %1\lib\???repea.lib %1\SAVECDD >nul
copy %1\clarion.app %1\SAVECDD >nul
ECHO ╔════════════════════════════════════════════════╗
ECHO ║ Verifying the files were copied ║
ECHO ╚════════════════════════════════════════════════╝
if not exist %1\SAVECDD\clarion.tpl GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion1.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion2.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion3.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion4.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion5.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion6.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion7.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion8.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion9.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\clario90.tpx GOTO COPY_FAILED
if not exist %1\SAVECDD\appgn.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\txted.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\envir.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\hlped.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\rptwr.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\cshell.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\dbmmg.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\dcted.txt GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion.hlp GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion3.hlp GOTO COPY_FAILED
if not exist %1\SAVECDD\editor.hlp GOTO COPY_FAILED
if not exist %1\SAVECDD\cshell.hlp GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion.sty GOTO COPY_FAILED
if not exist %1\SAVECDD\standard.sty GOTO COPY_FAILED
if not exist %1\SAVECDD\neon.sty GOTO COPY_FAILED
if not exist %1\SAVECDD\browse.cla GOTO COPY_FAILED
if not exist %1\SAVECDD\browse.pr GOTO COPY_FAILED
if not exist %1\SAVECDD\browse.inc GOTO COPY_FAILED
if not exist %1\SAVECDD\DDVbrows.dll GOTO COPY_FAILED
if not exist %1\SAVECDD\DDVbrows.lib GOTO COPY_FAILED
if not exist %1\SAVECDD\DOVbrows.lib GOTO COPY_FAILED
if not exist %1\SAVECDD\DXVbrows.lib GOTO COPY_FAILED
if not exist %1\SAVECDD\repeat.cla GOTO COPY_FAILED
if not exist %1\SAVECDD\repeat.pr GOTO COPY_FAILED
if not exist %1\SAVECDD\repeat.inc GOTO COPY_FAILED
if not exist %1\SAVECDD\DDVrepea.dll GOTO COPY_FAILED
if not exist %1\SAVECDD\DDVrepea.lib GOTO COPY_FAILED
if not exist %1\SAVECDD\DOVrepea.lib GOTO COPY_FAILED
if not exist %1\SAVECDD\DXVrepea.lib GOTO COPY_FAILED
if not exist %1\SAVECDD\clarion.app GOTO COPY_FAILED
ECHO ╔════════════════════════════════════════════════╗
ECHO ║ File copies have been verified! ║
ECHO ╚════════════════════════════════════════════════╝
YESNO Should we DELETE the ORIGINAL files we just backed up? [Y/N]
IF ERRORLEVEL 1 GOTO skip_delete
del %1\clarion.tpl >nul
del %1\clarion1.tpx >nul
del %1\clarion2.tpx >nul
del %1\clarion3.tpx >nul
del %1\clarion4.tpx >nul
del %1\clarion5.tpx >nul
del %1\clarion6.tpx >nul
del %1\clarion7.tpx >nul
del %1\clarion8.tpx >nul
del %1\clarion9.tpx >nul
del %1\clario90.tpx >nul
del %1\appgn.txt >nul
del %1\clarion.txt >nul
del %1\txted.txt >nul
del %1\envir.txt >nul
del %1\hlped.txt >nul
del %1\rptwr.txt >nul
del %1\cshell.txt >nul
del %1\dbmmg.txt >nul
del %1\dcted.txt >nul
del %1\clarion.hlp >nul
del %1\clarion3.hlp >nul
del %1\editor.hlp >nul
del %1\cshell.hlp >nul
del %1\clarion.sty >nul
del %1\standard.sty >nul
del %1\neon.sty >nul
del %1\browse.cla >nul
del %1\browse.pr >nul
del %1\browse.inc >nul
del %1\repeat.cla >nul
del %1\repeat.pr >nul
del %1\repeat.inc >nul
del %1\clarion.app >nul
GOTO NEXT_PHASE
:COPY_FAILED
ECHO ╔═══════════════════════════════════════════════╗
ECHO ║ WARNING: ║
ECHO ║ Cannot verify the file COPY was correct. ║
ECHO ║ Files WILL NOT BE DELETED ║
ECHO ╚═══════════════════════════════════════════════╝
GOTO skip_delete
:skip_delete
:skip_backup
:NEXT_PHASE
ECHO ╔════════════════════════════════════════════════════════════════════╗
ECHO ║ Now applying patch to upgrade CDD 3006 to revision 3007 ║
ECHO ║ If an error occurs during the PATCH process an Error file will ║
ECHO ║ be created as PATCH.ERR ║
ECHO ╚════════════════════════════════════════════════════════════════════╝
PATCH %1 -E CDD6TO7.RTP
PATCH %1 -E 6TO7CONT.RTP
COPY %1\*.LIB %1\LIB\*.* >NUL
DEL %1\*.LIB >NUL
PATCH %1\DOC -E 3007DOC.RTP
COPY %1\*.DOC %1\DOC >NUL
DEL %1\*.DOC >NUL
PATCH %1\EXAMPLE -E 3007EXAM.RTP
ECHO *
ECHO *
GOTO patch_complete
:NOTADIR
ECHO ╔═════════════════════════════════╗
ECHO ║ CANNOT FIND A DIRECTORY NAMED: ║ " %1 "
ECHO ╚═════════════════════════════════╝
GOTO SYNTAX
:SYNTAX
ECHO ╔═════════════════════════════════════════════════════════════╗
ECHO ║ This patch should be applied by UNZIPPING P3007.ZIP ║
ECHO ║ then typing: ║
ECHO ║ ║
ECHO ║ CDD6TO7 [DRIVE:\DIRECTORY] ║
ECHO ║ ║
ECHO ║ where [DRIVE:\DIRECTORY] is the name of the drive and path ║
ECHO ║ where CDD 3.0 is installed ║
ECHO ║ ║
ECHO ║ ║
ECHO ║ example: if CDD 3.0 is installed in C:\Clarion3 ║
ECHO ║ then type CDD6TO7 C:\Clarion3 ║
ECHO ║ ║
ECHO ╚═════════════════════════════════════════════════════════════╝
GOTO EXIT
:ERRORFILE
ECHO An error occurred when Patch.exe was opening %1\Patch.err
ECHO ╔════════════════════════════════════════════════════════════════════╗
ECHO ║ The probable cause is some type of DOS error, retry the operation ║
ECHO ║ after checking the disks integrity. ║
ECHO ╚════════════════════════════════════════════════════════════════════╝
GOTO EXIT
:BADVER
ECHO CANNOT find Clarion3.exe version 3006 installed in %1
ECHO ╔════════════════════════════════════════════════════════════════════════╗
ECHO ║ error ept0036: Old file not found. However, a file of the same name ║
ECHO ║ was found. No update done since file contents do not match. ║
ECHO ║ ║
ECHO ║ PATCH was unable to locate an exact match for the original file to ║
ECHO ║ be updated. However, PATCH was able to locate a file with the same ║
ECHO ║ name as the original file. However, the file found did not have either ║
ECHO ║ the same size or checksum as the actual original file that PATCH is ║
ECHO ║ seeking in order to perform the update. ║
ECHO ╚════════════════════════════════════════════════════════════════════════╝
GOTO EXIT
:BADVER_15
ECHO ╔════════════════════════════════════════════════════════════════════════╗
ECHO ║ ║
ECHO ║ CANNOT find Clarion3.exe version 3006 ║
ECHO ║ error ept0015: Old file does not exist ║
ECHO ║ ║
ECHO ║ PATCH needs Bytes from the existing version of a file in order to build║
ECHO ║ the new file. However, it was unable to locate the old file. ║
ECHO ╚════════════════════════════════════════════════════════════════════════╝
GOTO EXIT
:patch_complete
IF NOT EXIST %1\PATCH.ERR GOTO noerrors
ECHO
ECHO ╔═════════════════════════════════════════════════════╗
ECHO ║ PATCH HAS ERRORs, press any key to view error file ║
ECHO ║ after viewing the errors you can rerun the patch ║
ECHO ╠═════════════════════════════════════════════════════╣
ECHO ║ The following errors can be ignored: ║
ECHO ║ ║
ECHO ║ ept0016: New file already exists ║
ECHO ║ ept0024: New file already exists ║
ECHO ╚═════════════════════════════════════════════════════╝
EDITOR %1\PATCH.ERR
CLS
ECHO ╔══════════════════════════════════════════════════════════════════════╗
ECHO ║ A complete install set is available from Clarion Customer Service ║
ECHO ║ at 305-785-4555 for $10.00 plus shipping charges. ║
ECHO ║ ║
ECHO ╚══════════════════════════════════════════════════════════════════════╝
pause
GOTO EXIT
:missing_file
ECHO ╔════════════════════════════════════════════════════════════╗
ECHO ║ Cannot locate patch file(s) ║
ECHO ║ This patch should be applied by UNZIPPING P3007.ZIP ║
ECHO ║ then typing: ║
ECHO ║ CDD6TO7 [DRIVE:\DIRECTORY] ║
ECHO ╚════════════════════════════════════════════════════════════╝
GOTO EXIT
:nospace
ECHO ╔════════════════════════════════════════════════════════════╗
ECHO ║ ║
ECHO ║ There is insufficient disk space to apply the Patch, ║
ECHO ║ please free up some space and reapply the Patch. ║
ECHO ║ ║
ECHO ╚════════════════════════════════════════════════════════════╝
GOTO EXIT
:BAD_PATCHFILE
ECHO ╔════════════════════════════════════════════════════════════╗
ECHO ║ error ept0009: ║
ECHO ║ PATCH.EXE was unable to read the correct information ║
ECHO ║ from the patch file. Get a new copy and rerun the PATCH ║
ECHO ║ ║
ECHO ╚════════════════════════════════════════════════════════════╝
GOTO EXIT
:BAD_PATCHEXE
ECHO ╔════════════════════════════════════════════════════════════╗
ECHO ║ error ept0008: PATCH.EXE and Patch file are incompatible ║
ECHO ║ ║
ECHO ║ You need a new copy of PATCH.EXE to apply this patch. ║
ECHO ║ ║
ECHO ╚════════════════════════════════════════════════════════════╝
GOTO EXIT
:dirtest_failed
ECHO Unable to create directory %1\SAVECDD
ECHO ╔═══════════════════════════════════════════════════════╗
ECHO ║ Cannot perform backup of files, we suggest you ║
ECHO ║ backup your files and then rerun the patch ║
ECHO ║ but answer NO to the backup prompt. ║
ECHO ╚═══════════════════════════════════════════════════════╝
GOTO EXIT
:noerrors
ECHO
ECHO ╔═════════════════════════════════════════════════╗
ECHO ║ Patch is complete, no errors encountered! ║
ECHO ╚═════════════════════════════════════════════════╝
:EXIT